home *** CD-ROM | disk | FTP | other *** search
/ Giga Games 1 / Giga Games.iso / net / usenet / volume7 / nethack3 / patch4a < prev    next >
Encoding:
Internet Message Format  |  1989-10-02  |  59.8 KB

  1. Path: uunet!zephyr.ens.tek.com!tekgen!tekred!saab!billr
  2. From: billr@saab.CNA.TEK.COM (Bill Randle)
  3. Newsgroups: comp.sources.games
  4. Subject: v08i037:  NetHack3 -  display oriented dungeons & dragons (Ver. 3.0), Patch4a
  5. Message-ID: <4627@tekred.CNA.TEK.COM>
  6. Date: 29 Sep 89 21:07:24 GMT
  7. Sender: nobody@tekred.CNA.TEK.COM
  8. Lines: 2032
  9. Approved: billr@saab.CNA.TEK.COM
  10.  
  11. Submitted-by: Izchak Miller <izchak@linc.cis.upenn.edu>
  12. Posting-number: Volume 8, Issue 37
  13. Archive-name: NetHack3/Patch4a
  14. Patch-To: NetHack3: Volume 7, Issue 56-93
  15.  
  16.     [Here is patch #4 for NetHack3 (in 11 parts).  Unpack all
  17.      11 parts in your top-level NetHack directory then execute
  18.      the do_patch4.sh shell script (or the equivalent if you're
  19.      not on a Unix machine, or don't have 'sh').  -br]
  20.  
  21. [[ From the development team...
  22. -------------
  23. UPDATE4
  24. -------------
  25. NOTICE:  The changes which were made in the code make all save and bones 
  26. files absolete.  Once Patch 4 is applied, all the old save and bones files
  27. must be thrown out.
  28.  
  29.  
  30. Here is a list of the main changes:
  31.  
  32. Object and monster types got a new field specifying their color, so things 
  33. can now appear in "living color" instead having one color for all monsters,
  34. one for all weapons, and so on.
  35.  
  36. References to monsters and objects on the floor were moved to new structures,
  37. which support the better color handling as well as provide yet faster access.
  38.  
  39. David Gentzel provided a port for VMS.  Although extensively tested by
  40. David and others, and found to be sound, it probably needs further
  41. refinements.  We are appealing to those of you who know VMS (none of us
  42. does..) to join David in his efforts to refine the VMS code.
  43.  
  44. Much of the *main.c code was moved to a new file, to avoid having to update
  45. that common code in three different *main.c files.
  46.  
  47. VARARG handling was ifdef'd to satisfy ANSI compilers.
  48.  
  49. Almost all grey creatures now join the other gray creatures.
  50.  
  51. Monsters will no longer be created in the same room as the player, and should
  52. no longer want to end up in the SE corner of the dungeon.
  53.  
  54. Lycanthropy is now considered a "major problem" (allowing for appeal to the
  55. gods through prayer), some artifacts are associated with particular character
  56. classes, various oddities involving statues, digging, iron balls, and 
  57. throwing have been removed, and many other bugs, both major and minor, were
  58. fixed.]]
  59.  
  60.  
  61. #! /bin/sh
  62. # This is a shell archive.  Remove anything before this line, then unpack
  63. # it by saving it into a file and typing "sh file".  To overwrite existing
  64. # files, type "sh file -c".  You can also feed this as standard input via
  65. # unshar, or by typing "sh <file", e.g..  If this archive is complete, you
  66. # will see the following message at the end:
  67. #        "End of archive 1 (of 11)."
  68. # Contents:  patches04a
  69. # Wrapped by billr@saab on Fri Sep 29 13:13:17 1989
  70. PATH=/bin:/usr/bin:/usr/ucb ; export PATH
  71. if test -f 'patches04a' -a "${1}" != "-c" ; then 
  72.   echo shar: Will not clobber existing file \"'patches04a'\"
  73. else
  74. echo shar: Extracting \"'patches04a'\" \(55684 characters\)
  75. sed "s/^X//" >'patches04a' <<'END_OF_FILE'
  76. X*** src/Old/Makefile.src    Wed Sep 27 12:16:31 1989
  77. X--- src/Makefile.src    Tue Sep 26 19:07:09 1989
  78. X***************
  79. X*** 5,11 ****
  80. X  # Makefile.3B2, Makefile.att, and Makefile.tos.
  81. X  # Set SYSTEM to one of:
  82. X  #    'Sysunix'    -- generic UNIX
  83. X- #    'Sysxenix'    -- 286 Xenix (386 Xenix should use Sysunix)
  84. X  #    'Sys3B2'    -- AT&T 3B2, 3B5, etc.
  85. X  #    'Sysatt'    -- AT&T UNIXPC, 7300, 3B1
  86. X  #    'Systos'    -- Atari
  87. X--- 5,10 ----
  88. X***************
  89. X*** 37,44 ****
  90. X  
  91. X  # flags may have to be changed as required
  92. X  # flags for 286 Xenix:
  93. X! # CFLAGS = -O -Gt24 -LARGE -Ml -I../include
  94. X! # LFLAGS = -Ml
  95. X  # flags for 286 Microport SysV-AT
  96. X  # CFLAGS = -DDUMB -Ml -I../include
  97. X  # LFLAGS = -Ml
  98. X--- 36,43 ----
  99. X  
  100. X  # flags may have to be changed as required
  101. X  # flags for 286 Xenix:
  102. X! # CFLAGS = -Ml2t16 -O -LARGE -I../include
  103. X! # LFLAGS = -Ml -F 4000 -SEG 512
  104. X  # flags for 286 Microport SysV-AT
  105. X  # CFLAGS = -DDUMB -Ml -I../include
  106. X  # LFLAGS = -Ml
  107. X***************
  108. X*** 50,63 ****
  109. X  
  110. X  # object files for makedefs
  111. X  MAKEOBJS = makedefs.o monst.o objects.o panic.o
  112. X- # objects files for makedefs for 286 Xenix
  113. X- # MAKEOBJS = Smakedefs.o Smonst.o Sobjects.o Spanic.o
  114. X  
  115. X  # object files for special levels compiler
  116. X  SPLEVOBJS = lev_comp.o lev_lex.o lev_main.o alloc.o monst.o objects.o panic.o
  117. X- # object files for special levels compiler for 286 Xenix
  118. X- # SPLEVOBJS = Slev_comp.o Slev_lex.o Slev_main.o Salloc.o Smonst.o Sobjects.o \
  119. X- #          Spanic.o
  120. X  
  121. X  # on some systems the termcap library is in -ltermcap or -lcurses
  122. X  # on 386 Xenix, the -ltermlib tputs() seems not to work; use -lcurses instead
  123. X--- 49,57 ----
  124. X***************
  125. X*** 87,103 ****
  126. X  # other things that have to be reconfigured are in config.h,
  127. X  # {unixconf.h, pcconf.h, tosconf.h}, and possibly system.h
  128. X  
  129. X! HACKCSRC = alloc.c apply.c artifact.c attrib.c bones.c cmd.c dbridge.c decl.c\
  130. X!        demon.c do.c do_name.c do_wear.c dog.c dogmove.c dokick.c dothrow.c\
  131. X!         eat.c end.c engrave.c exper.c extralev.c fountain.c getline.c hack.c\
  132. X!        invent.c ioctl.c lock.c mail.c makemon.c mcastu.c mhitm.c mhitu.c\
  133. X!        mklev.c mkmaze.c mkobj.c mkroom.c mon.c mondata.c monmove.c monst.c\
  134. X!        mthrowu.c music.c o_init.c objects.c objnam.c options.c pager.c\
  135. X!        pickup.c polyself.c potion.c pray.c pri.c priest.c prisym.c read.c\
  136. X!         restore.c rip.c rnd.c rumors.c save.c search.c shk.c shknam.c sit.c\
  137. X!        sounds.c sp_lev.c spell.c steal.c termcap.c timeout.c topl.c\
  138. X!        topten.c track.c trap.c u_init.c uhitm.c vault.c version.c weapon.c\
  139. X!        were.c wield.c wizard.c worm.c worn.c write.c zap.c
  140. X  
  141. X  # all .c that are part of the main NetHack program and are not system specific
  142. X  
  143. X--- 81,98 ----
  144. X  # other things that have to be reconfigured are in config.h,
  145. X  # {unixconf.h, pcconf.h, tosconf.h}, and possibly system.h
  146. X  
  147. X! HACKCSRC = allmain.c alloc.c apply.c artifact.c attrib.c bones.c cmd.c\
  148. X!        dbridge.c decl.c demon.c do.c do_name.c do_wear.c dog.c dogmove.c\
  149. X!        dokick.c dothrow.c eat.c end.c engrave.c exper.c extralev.c\
  150. X!        fountain.c getline.c hack.c invent.c ioctl.c lock.c mail.c makemon.c\
  151. X!        mcastu.c mhitm.c mhitu.c mklev.c mkmaze.c mkobj.c mkroom.c mon.c\
  152. X!        mondata.c monmove.c monst.c mthrowu.c music.c o_init.c objects.c\
  153. X!        objnam.c options.c pager.c pickup.c polyself.c potion.c pray.c pri.c\
  154. X!        priest.c prisym.c read.c restore.c rip.c rnd.c rumors.c save.c\
  155. X!        search.c shk.c shknam.c sit.c sounds.c sp_lev.c spell.c steal.c\
  156. X!        termcap.c timeout.c topl.c topten.c track.c trap.c u_init.c uhitm.c\
  157. X!        vault.c version.c weapon.c were.c wield.c wizard.c worm.c worn.c\
  158. X!        write.c zap.c
  159. X  
  160. X  # all .c that are part of the main NetHack program and are not system specific
  161. X  
  162. X***************
  163. X*** 122,131 ****
  164. X  
  165. X  SOURCES = $(CSOURCES) $(HSOURCES)
  166. X  
  167. X! HOBJ = alloc.o apply.o artifact.o attrib.o bones.o cmd.o dbridge.o decl.o\
  168. X!     demon.o do.o do_name.o do_wear.o dog.o dogmove.o dokick.o dothrow.o\
  169. X!      eat.o end.o engrave.o exper.o extralev.o fountain.o getline.o hack.o\
  170. X!     invent.o ioctl.o lock.o mail.o main.o makemon.o mcastu.o mhitm.o\
  171. X      mhitu.o mklev.o mkmaze.o mkobj.o mkroom.o mon.o mondata.o monmove.o\
  172. X      monst.o mthrowu.o music.o o_init.o objects.o objnam.o options.o pager.o\
  173. X      pickup.o polyself.o potion.o pray.o pri.o priest.o prisym.o read.o\
  174. X--- 117,126 ----
  175. X  
  176. X  SOURCES = $(CSOURCES) $(HSOURCES)
  177. X  
  178. X! HOBJ = allmain.o alloc.o apply.o artifact.o attrib.o bones.o cmd.o dbridge.o\
  179. X!     decl.o demon.o do.o do_name.o do_wear.o dog.o dogmove.o dokick.o\
  180. X!     dothrow.o eat.o end.o engrave.o exper.o extralev.o fountain.o getline.o\
  181. X!     hack.o invent.o ioctl.o lock.o mail.o main.o makemon.o mcastu.o mhitm.o\
  182. X      mhitu.o mklev.o mkmaze.o mkobj.o mkroom.o mon.o mondata.o monmove.o\
  183. X      monst.o mthrowu.o music.o o_init.o objects.o objnam.o options.o pager.o\
  184. X      pickup.o polyself.o potion.o pray.o pri.o priest.o prisym.o read.o\
  185. X***************
  186. X*** 144,154 ****
  187. X      @$(CC) $(LFLAGS) -o $(GAME) $(HOBJ) $(TERMLIB)
  188. X      @touch Sysunix
  189. X  
  190. X- Sysxenix:    $(HOBJ) Makefile
  191. X-     @echo "Loading ..."
  192. X-     @$(CC) $(LFLAGS) -m hack.map -o $(GAME) /lib/Lsignal.o $(HOBJ) $(TERMLIB) -SEG#256
  193. X-     @touch Sysxenix
  194. X- 
  195. X  Sys3B2:    $(HOBJ) Makefile
  196. X      @echo "Loading ..."
  197. X      @$(CC) $(LFLAGS) -o $(GAME) $(HOBJ) $(TERMLIB) -lmalloc
  198. X--- 139,144 ----
  199. X***************
  200. X*** 222,264 ****
  201. X      $(LEX) lev_comp.l
  202. X      mv lex.yy.c lev_lex.c
  203. X  
  204. X- # special stuff for 286 Xenix makedefs & lev_comp
  205. X- 
  206. X- Smakedefs.o:    makedefs.c ../include/config.h ../include/permonst.h
  207. X-     cp makedefs.c Smakedefs.c
  208. X-     $(CC) -O -c Smakedefs.c
  209. X- 
  210. X- Slev_comp.o:  lev_comp.c ../include/hack.h ../include/sp_lev.h
  211. X-     cp lev_comp.c Slev_comp.c
  212. X-     $(CC) -O -c Slev_comp.c
  213. X- 
  214. X- Slev_lex.o: lev_lex.c ../include/hack.h ../include/sp_lev.h ../include/lev_comp.h
  215. X-     cp lev_lex.c Slev_lex.c
  216. X-     $(CC) -O -c Slev_lex.c
  217. X- 
  218. X- Slev_main.o: lev_main.c ../include/hack.h ../include/sp_lev.h
  219. X-     cp lev_main.c Slev_main.c
  220. X-     $(CC) -O -c Slev_main.c
  221. X- 
  222. X- Salloc.o:    alloc.c
  223. X-     cp alloc.c Salloc.c
  224. X-     $(CC) -O -c Salloc.c
  225. X- 
  226. X- Smonst.o:    monst.c ../include/config.h ../include/permonst.h \
  227. X-         ../include/monsym.h ../include/epri.h ../include/eshk.h \
  228. X-         ../include/vault.h
  229. X-     cp monst.c Smonst.c
  230. X-     $(CC) -O -c Smonst.c
  231. X- 
  232. X- Sobjects.o:    objects.c ../include/config.h ../include/obj.h \
  233. X-         ../include/objclass.h ../include/prop.h
  234. X-     cp objects.c Sobjects.c
  235. X-     $(CC) -O -c Sobjects.c
  236. X- 
  237. X- Spanic.o:    panic.c
  238. X-     cp panic.c Spanic.c
  239. X-     $(CC) -O -c Spanic.c
  240. X- 
  241. X  #
  242. X  #    The following include files depend on makedefs to be created.
  243. X  #    As a result, they are not defined in HACKINCL, instead, their
  244. X--- 212,217 ----
  245. X***************
  246. X*** 370,375 ****
  247. X--- 323,329 ----
  248. X  
  249. X  # DO NOT DELETE THIS LINE
  250. X  
  251. X+ allmain.o:  ../include/hack.h
  252. X  alloc.o:  ../include/config.h
  253. X  apply.o:  ../include/hack.h ../include/edog.h
  254. X  artifact.o:  ../include/hack.h ../include/artifact.h
  255. X***************
  256. X*** 406,419 ****
  257. X  mkmaze.o:  ../include/hack.h
  258. X  mkobj.o:  ../include/hack.h
  259. X  mkroom.o:  ../include/hack.h
  260. X! mon.o:  ../include/hack.h ../include/mfndpos.h ../include/artifact.h
  261. X  mondata.o:  ../include/hack.h ../include/eshk.h ../include/epri.h
  262. X  monmove.o:  ../include/hack.h ../include/mfndpos.h ../include/artifact.h
  263. X! monst.o:  ../include/config.h ../include/permonst.h ../include/monsym.h ../include/eshk.h ../include/vault.h ../include/epri.h
  264. X  mthrowu.o:  ../include/hack.h
  265. X  music.o:  ../include/hack.h
  266. X  o_init.o:  ../include/hack.h
  267. X! objects.o:  ../include/config.h ../include/obj.h ../include/objclass.h ../include/prop.h
  268. X  objnam.o:  ../include/hack.h
  269. X  options.o:  ../include/hack.h
  270. X  pager.o:  ../include/hack.h
  271. X--- 360,373 ----
  272. X  mkmaze.o:  ../include/hack.h
  273. X  mkobj.o:  ../include/hack.h
  274. X  mkroom.o:  ../include/hack.h
  275. X! mon.o:  ../include/hack.h ../include/mfndpos.h ../include/artifact.h ../include/wseg.h
  276. X  mondata.o:  ../include/hack.h ../include/eshk.h ../include/epri.h
  277. X  monmove.o:  ../include/hack.h ../include/mfndpos.h ../include/artifact.h
  278. X! monst.o:  ../include/config.h ../include/permonst.h ../include/monsym.h ../include/eshk.h ../include/vault.h ../include/epri.h ../include/decl.h
  279. X  mthrowu.o:  ../include/hack.h
  280. X  music.o:  ../include/hack.h
  281. X  o_init.o:  ../include/hack.h
  282. X! objects.o:  ../include/config.h ../include/obj.h ../include/objclass.h ../include/prop.h ../include/decl.h
  283. X  objnam.o:  ../include/hack.h
  284. X  options.o:  ../include/hack.h
  285. X  pager.o:  ../include/hack.h
  286. X***************
  287. X*** 421,427 ****
  288. X  polyself.o:  ../include/hack.h
  289. X  potion.o:  ../include/hack.h
  290. X  pray.o:  ../include/hack.h
  291. X! pri.o:  ../include/hack.h
  292. X  priest.o:  ../include/hack.h ../include/mfndpos.h ../include/eshk.h ../include/epri.h
  293. X  prisym.o:  ../include/hack.h ../include/wseg.h ../include/lev.h
  294. X  read.o:  ../include/hack.h
  295. X--- 375,381 ----
  296. X  polyself.o:  ../include/hack.h
  297. X  potion.o:  ../include/hack.h
  298. X  pray.o:  ../include/hack.h
  299. X! pri.o:  ../include/hack.h ../include/epri.h
  300. X  priest.o:  ../include/hack.h ../include/mfndpos.h ../include/eshk.h ../include/epri.h
  301. X  prisym.o:  ../include/hack.h ../include/wseg.h ../include/lev.h
  302. X  read.o:  ../include/hack.h
  303. X***************
  304. X*** 447,453 ****
  305. X  u_init.o:  ../include/hack.h
  306. X  uhitm.o:  ../include/hack.h ../include/artifact.h
  307. X  vault.o:  ../include/hack.h ../include/vault.h
  308. X! version.o:  ../include/hack.h ../include/date.h
  309. X  weapon.o:  ../include/hack.h
  310. X  were.o:  ../include/hack.h
  311. X  wield.o:  ../include/hack.h
  312. X--- 401,407 ----
  313. X  u_init.o:  ../include/hack.h
  314. X  uhitm.o:  ../include/hack.h ../include/artifact.h
  315. X  vault.o:  ../include/hack.h ../include/vault.h
  316. X! version.o:  ../include/hack.h ../include/date.h ../include/patchlevel.h
  317. X  weapon.o:  ../include/hack.h
  318. X  were.o:  ../include/hack.h
  319. X  wield.o:  ../include/hack.h
  320. X***************
  321. X*** 460,468 ****
  322. X              touch ../include/config.h
  323. X  ../include/decl.h:  ../include/spell.h ../include/obj.h ../include/you.h ../include/onames.h ../include/pm.h
  324. X              touch ../include/decl.h
  325. X! ../include/global.h:  ../include/coord.h ../include/unixconf.h ../include/pcconf.h ../include/tosconf.h ../include/amiconf.h
  326. X              touch ../include/global.h
  327. X! ../include/hack.h:  ../include/config.h ../include/decl.h ../include/monsym.h ../include/mkroom.h ../include/objclass.h ../include/gold.h ../include/trap.h ../include/flag.h ../include/rm.h
  328. X              touch ../include/hack.h
  329. X  ../include/permonst.h:  ../include/monattk.h ../include/monflag.h
  330. X              touch ../include/permonst.h
  331. X--- 414,422 ----
  332. X              touch ../include/config.h
  333. X  ../include/decl.h:  ../include/spell.h ../include/obj.h ../include/you.h ../include/onames.h ../include/pm.h
  334. X              touch ../include/decl.h
  335. X! ../include/global.h:  ../include/coord.h ../include/vmsconf.h ../include/unixconf.h ../include/pcconf.h ../include/tosconf.h ../include/amiconf.h
  336. X              touch ../include/global.h
  337. X! ../include/hack.h:  ../include/config.h ../include/decl.h ../include/monsym.h ../include/mkroom.h ../include/objclass.h ../include/gold.h ../include/trap.h ../include/flag.h ../include/rm.h ../include/extern.h
  338. X              touch ../include/hack.h
  339. X  ../include/permonst.h:  ../include/monattk.h ../include/monflag.h
  340. X              touch ../include/permonst.h
  341. X*** /dev/null    Wed Sep 27 11:17:44 1989
  342. X--- src/allmain.c    Tue Sep 26 18:59:13 1989
  343. X***************
  344. X*** 0 ****
  345. X--- 1,253 ----
  346. X+ /*    SCCS Id: @(#)allmain.c    3.0    89/09/26
  347. X+ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  348. X+ /* NetHack may be freely redistributed.  See license for details. */
  349. X+ 
  350. X+ /* various code that was replicated in *main.c */
  351. X+ 
  352. X+ #include "hack.h"
  353. X+ 
  354. X+ #ifndef NO_SIGNAL
  355. X+ #include <signal.h>
  356. X+ #endif
  357. X+ 
  358. X+ int (*afternmv)();
  359. X+ int (*occupation)();
  360. X+ 
  361. X+ void
  362. X+ moveloop()
  363. X+ {
  364. X+ #ifdef MSDOS
  365. X+     char ch;
  366. X+     int abort;
  367. X+ #endif
  368. X+ 
  369. X+     for(;;) {
  370. X+         if(flags.move) {    /* actual time passed */
  371. X+ 
  372. X+ #ifdef SOUNDS
  373. X+             dosounds();
  374. X+ #endif
  375. X+             settrack();
  376. X+ 
  377. X+             if(moves%2 == 0 ||
  378. X+               (!(Fast & ~INTRINSIC) && (!Fast || rn2(3)))) {
  379. X+                 movemon();
  380. X+ #ifdef HARD
  381. X+                 if(!rn2(u.udemigod?25:(dlevel>30)?50:70))
  382. X+ #else
  383. X+                 if(!rn2(70))
  384. X+ #endif
  385. X+                     (void) makemon((struct permonst *)0, 0, 0);
  386. X+                 ++monstermoves;
  387. X+             }
  388. X+             if(Glib) glibr();
  389. X+             timeout();
  390. X+             ++moves;
  391. X+ #ifdef THEOLOGY
  392. X+             if (u.ublesscnt)  u.ublesscnt--;
  393. X+ #endif
  394. X+             if(flags.time) flags.botl = 1;
  395. X+ #ifdef POLYSELF
  396. X+             if(u.mtimedone)
  397. X+                 if(u.mh < 1) rehumanize();
  398. X+             else
  399. X+ #endif
  400. X+                 if(u.uhp < 1) {
  401. X+                 You("die...");
  402. X+                 done(DIED);
  403. X+                 }
  404. X+ #ifdef POLYSELF
  405. X+             if (u.mtimedone) {
  406. X+                 if (u.mh < u.mhmax) {
  407. X+                 if (Regeneration || !(moves%20)) {
  408. X+                     flags.botl = 1;
  409. X+                     u.mh++;
  410. X+                 }
  411. X+                 }
  412. X+             }
  413. X+ #endif
  414. X+             if(u.uhp < u.uhpmax) {
  415. X+                 if(u.ulevel > 9) {
  416. X+                     int heal;
  417. X+ 
  418. X+                     if(HRegeneration || !(moves%3)) {
  419. X+                     flags.botl = 1;
  420. X+                     if (ACURR(A_CON) <= 12) heal = 1;
  421. X+                     else heal = rnd((int) ACURR(A_CON)-12);
  422. X+                     if (heal > u.ulevel-9) heal = u.ulevel-9;
  423. X+                     u.uhp += heal;
  424. X+                     if(u.uhp > u.uhpmax)
  425. X+                         u.uhp = u.uhpmax;
  426. X+                     }
  427. X+                 } else if(HRegeneration ||
  428. X+                     (!(moves%((MAXULEV+12)/(u.ulevel+2)+1)))) {
  429. X+                     flags.botl = 1;
  430. X+                     u.uhp++;
  431. X+                 }
  432. X+             }
  433. X+ #ifdef SPELLS
  434. X+             if ((u.uen<u.uenmax) && (!(moves%(19-ACURR(A_INT)/2)))) {
  435. X+                 u.uen += rn2((int)ACURR(A_WIS)/5 + 1) + 1;
  436. X+                 if (u.uen > u.uenmax)  u.uen = u.uenmax;
  437. X+                 flags.botl = 1;
  438. X+             }
  439. X+ #endif
  440. X+             if(Teleportation && !rn2(85)) tele();
  441. X+ #ifdef POLYSELF
  442. X+             if(Polymorph && !rn2(100))
  443. X+                 polyself();
  444. X+             if(u.ulycn >= 0 && !rn2(80 - (20 * night())))
  445. X+                 you_were();
  446. X+ #endif
  447. X+             if(Searching && multi >= 0) (void) dosearch0(1);
  448. X+             hatch_eggs();
  449. X+             gethungry();
  450. X+             invault();
  451. X+             amulet();
  452. X+ #ifdef HARD
  453. X+             if (!rn2(40+(int)(ACURR(A_DEX)*3))) u_wipe_engr(rnd(3));
  454. X+             if (u.udemigod) {
  455. X+                 if (u.udg_cnt) u.udg_cnt--;
  456. X+                 if (!u.udg_cnt) {
  457. X+                     intervene();
  458. X+                     u.udg_cnt = rn1(200, 50);
  459. X+                 }
  460. X+             }
  461. X+ #endif
  462. X+             restore_attrib();
  463. X+         }
  464. X+         if(multi < 0) {
  465. X+             if(!++multi){
  466. X+                 pline(nomovemsg ? nomovemsg :
  467. X+                     "You can move again.");
  468. X+                 nomovemsg = 0;
  469. X+                 if(afternmv) (*afternmv)();
  470. X+                 afternmv = 0;
  471. X+             }
  472. X+         }
  473. X+ 
  474. X+         find_ac();
  475. X+         if(!flags.mv || Blind)
  476. X+         {
  477. X+             seeobjs();
  478. X+             seemons();
  479. X+             seeglds();
  480. X+             nscr();
  481. X+         }
  482. X+         if(flags.botl || flags.botlx) bot();
  483. X+ 
  484. X+         flags.move = 1;
  485. X+ 
  486. X+         if(multi >= 0 && occupation) {
  487. X+ #ifdef MSDOS
  488. X+             abort = 0;
  489. X+             if (kbhit()) {
  490. X+                 if ((ch = Getchar()) == ABORT)
  491. X+                     abort++;
  492. X+ # ifdef REDO
  493. X+                 else
  494. X+                     pushch(ch);
  495. X+ # endif /* REDO */
  496. X+             }
  497. X+             if(abort || monster_nearby())
  498. X+ #else
  499. X+             if(monster_nearby())
  500. X+ #endif
  501. X+                 stop_occupation();
  502. X+             else if ((*occupation)() == 0)
  503. X+                 occupation = 0;
  504. X+ #ifdef MSDOS
  505. X+             if (!(++occtime % 7))
  506. X+                 (void) fflush(stdout);
  507. X+ #endif
  508. X+             continue;
  509. X+         }
  510. X+ 
  511. X+         if((u.uhave_amulet || Clairvoyant) && 
  512. X+ #ifdef ENDGAME
  513. X+             dlevel != ENDLEVEL &&
  514. X+ #endif
  515. X+             !(moves%15) && !rn2(2)) do_vicinity_map();
  516. X+ 
  517. X+         u.umoved = FALSE;
  518. X+         if(multi > 0) {
  519. X+             lookaround();
  520. X+             if(!multi) {    /* lookaround may clear multi */
  521. X+                 flags.move = 0;
  522. X+                 continue;
  523. X+             }
  524. X+             if(flags.mv) {
  525. X+                 if(multi < COLNO && !--multi)
  526. X+                     flags.mv = flags.run = 0;
  527. X+                 domove();
  528. X+             } else {
  529. X+                 --multi;
  530. X+                 rhack(save_cm);
  531. X+             }
  532. X+         } else if(multi == 0) {
  533. X+ #ifdef MAIL
  534. X+             ckmailstatus();
  535. X+ #endif
  536. X+             rhack(NULL);
  537. X+         }
  538. X+         if(multi && multi%7 == 0)
  539. X+             (void) fflush(stdout);
  540. X+     }
  541. X+ }
  542. X+ 
  543. X+ void
  544. X+ stop_occupation()
  545. X+ {
  546. X+     if(occupation) {
  547. X+         You("stop %s.", occtxt);
  548. X+         occupation = 0;
  549. X+ #ifdef REDO
  550. X+         multi = 0;
  551. X+         pushch(0);
  552. X+ #endif
  553. X+     }
  554. X+ }
  555. X+ 
  556. X+ void
  557. X+ newgame() {
  558. X+ #ifdef DGK
  559. X+     gameDiskPrompt();
  560. X+ #endif
  561. X+ 
  562. X+     fobj = fcobj = invent = 0;
  563. X+     fmon = fallen_down = 0;
  564. X+     ftrap = 0;
  565. X+     fgold = 0;
  566. X+     flags.ident = 1;
  567. X+ 
  568. X+     init_objects();
  569. X+     u_init();
  570. X+ 
  571. X+ #ifndef NO_SIGNAL
  572. X+     (void) signal(SIGINT, (SIG_RET_TYPE) done1);
  573. X+ #endif
  574. X+ 
  575. X+     mklev();
  576. X+     u.ux = xupstair;
  577. X+     u.uy = yupstair;
  578. X+     (void) inshop();
  579. X+ 
  580. X+     setsee();
  581. X+     flags.botlx = 1;
  582. X+ 
  583. X+     /* Move the monster from under you or else
  584. X+      * makedog() will fail when it calls makemon().
  585. X+      *             - ucsfcgl!kneller
  586. X+      */
  587. X+     if(MON_AT(u.ux, u.uy)) mnexto(m_at(u.ux, u.uy));
  588. X+ 
  589. X+     (void) makedog();
  590. X+     seemons();
  591. X+ #ifdef NEWS
  592. X+     if(flags.nonews || !readnews())
  593. X+         /* after reading news we did docrt() already */
  594. X+ #endif
  595. X+         docrt();
  596. X+ 
  597. X+     return;
  598. X+ }
  599. X*** src/Old/apply.c    Wed Sep 27 11:18:07 1989
  600. X--- src/apply.c    Tue Sep 26 16:08:31 1989
  601. X***************
  602. X*** 31,37 ****
  603. X      while(range--) {
  604. X          bchx += ddx;
  605. X          bchy += ddy;
  606. X!         if(levl[bchx][bchy].mmask) {
  607. X              mtmp = m_at(bchx,bchy);
  608. X              break;
  609. X          }
  610. X--- 31,37 ----
  611. X      while(range--) {
  612. X          bchx += ddx;
  613. X          bchy += ddy;
  614. X!         if(MON_AT(bchx, bchy)) {
  615. X              mtmp = m_at(bchx,bchy);
  616. X              break;
  617. X          }
  618. X***************
  619. X*** 155,161 ****
  620. X          return;
  621. X      }
  622. X      lev = &levl[rx][ry];
  623. X!     if(lev->mmask) {
  624. X          mtmp = m_at(rx,ry);
  625. X          mstatusline(mtmp);
  626. X          if (mtmp->mundetected) {
  627. X--- 155,161 ----
  628. X          return;
  629. X      }
  630. X      lev = &levl[rx][ry];
  631. X!     if(MON_AT(rx, ry)) {
  632. X          mtmp = m_at(rx,ry);
  633. X          mstatusline(mtmp);
  634. X          if (mtmp->mundetected) {
  635. X***************
  636. X*** 288,294 ****
  637. X          return;
  638. X      }
  639. X  
  640. X!     if(levl[x][y].mmask == 0) {
  641. X          pline("There is no creature here.");
  642. X          return;
  643. X      }
  644. X--- 288,294 ----
  645. X          return;
  646. X      }
  647. X  
  648. X!     if(!MON_AT(x, y)) {
  649. X          pline("There is no creature here.");
  650. X          return;
  651. X      }
  652. X***************
  653. X*** 441,448 ****
  654. X      if(Fumbling && !rn2(3)) {
  655. X          switch(rn2(3)) {
  656. X          case 0:  if(!welded(uwep)) {
  657. X!                  You("fumble and drop your %s", xname(uwep));
  658. X                   dropx(uwep);
  659. X               } else {
  660. X                   pline("Ouch!  Your %s bounces and hits you!",
  661. X                  xname(uwep));
  662. X--- 441,449 ----
  663. X      if(Fumbling && !rn2(3)) {
  664. X          switch(rn2(3)) {
  665. X          case 0:  if(!welded(uwep)) {
  666. X!                  You("fumble and drop your %s.", xname(uwep));
  667. X                   dropx(uwep);
  668. X+                  setuwep((struct obj *)0);
  669. X               } else {
  670. X                   pline("Ouch!  Your %s bounces and hits you!",
  671. X                  xname(uwep));
  672. X***************
  673. X*** 516,523 ****
  674. X              digtxt = "You just broke a hole through the door.";
  675. X              if(!(lev->doormask & D_TRAPPED))
  676. X                  lev->doormask = D_BROKEN;
  677. X!         } else
  678. X!           digtxt = "Now what exactly was it that you were digging in?";
  679. X          mnewsym(dpx, dpy);
  680. X          prl(dpx, dpy);
  681. X          if (digtxt) pline(digtxt);    /* after mnewsym & prl */
  682. X--- 517,523 ----
  683. X              digtxt = "You just broke a hole through the door.";
  684. X              if(!(lev->doormask & D_TRAPPED))
  685. X                  lev->doormask = D_BROKEN;
  686. X!         } else return(0); /* statue or boulder got taken */
  687. X          mnewsym(dpx, dpy);
  688. X          prl(dpx, dpy);
  689. X          if (digtxt) pline(digtxt);    /* after mnewsym & prl */
  690. X***************
  691. X*** 537,543 ****
  692. X              IS_DOOR(lev->typ) ? "door" : "wall");
  693. X              return(0);
  694. X              }
  695. X!         }
  696. X          if(!did_dig_msg) {
  697. X              You("hit the %s with all your might.",
  698. X              sobj_at(STATUE, dpx, dpy) ? "statue" :
  699. X--- 537,545 ----
  700. X              IS_DOOR(lev->typ) ? "door" : "wall");
  701. X              return(0);
  702. X              }
  703. X!         } else if (!IS_ROCK(lev->typ) && !sobj_at(STATUE, dpx, dpy)
  704. X!                 && !sobj_at(BOULDER, dpx, dpy))
  705. X!             return(0); /* statue or boulder got taken */
  706. X          if(!did_dig_msg) {
  707. X              You("hit the %s with all your might.",
  708. X              sobj_at(STATUE, dpx, dpy) ? "statue" :
  709. X***************
  710. X*** 552,558 ****
  711. X  /* When will hole be finished? Very rough indication used by shopkeeper. */
  712. X  int
  713. X  holetime() {
  714. X!     return( (occupation == dig) ? (250 - dig_effort)/20 : -1);
  715. X  }
  716. X  
  717. X  void
  718. X--- 554,561 ----
  719. X  /* When will hole be finished? Very rough indication used by shopkeeper. */
  720. X  int
  721. X  holetime() {
  722. X!     if(occupation != dig || !in_shop(u.ux, u.uy)) return(-1);
  723. X!     return((250 - dig_effort)/20);
  724. X  }
  725. X  
  726. X  void
  727. X***************
  728. X*** 679,685 ****
  729. X          rx = u.ux + u.dx;
  730. X          ry = u.uy + u.dy;
  731. X          lev = &levl[rx][ry];
  732. X!         if(lev->mmask && attack(m_at(rx, ry)))
  733. X              return(1);
  734. X          if(!isok(rx, ry)) {
  735. X              pline("Clash!");
  736. X--- 682,688 ----
  737. X          rx = u.ux + u.dx;
  738. X          ry = u.uy + u.dy;
  739. X          lev = &levl[rx][ry];
  740. X!         if(MON_AT(rx, ry) && attack(m_at(rx, ry)))
  741. X              return(1);
  742. X          if(!isok(rx, ry)) {
  743. X              pline("Clash!");
  744. X***************
  745. X*** 1076,1082 ****
  746. X      } else if (!cansee(cc.x, cc.y)) {
  747. X          You("cannot see where to land!");
  748. X          return 0;
  749. X!     } else if (levl[cc.x][cc.y].mmask) {
  750. X          mtmp = m_at(cc.x, cc.y);
  751. X          You("cannot trample %s!", mon_nam(mtmp));
  752. X          return 0;
  753. X--- 1079,1085 ----
  754. X      } else if (!cansee(cc.x, cc.y)) {
  755. X          You("cannot see where to land!");
  756. X          return 0;
  757. X!     } else if (MON_AT(cc.x, cc.y)) {
  758. X          mtmp = m_at(cc.x, cc.y);
  759. X          You("cannot trample %s!", mon_nam(mtmp));
  760. X          return 0;
  761. X*** src/Old/artifact.c    Wed Sep 27 11:18:52 1989
  762. X--- src/artifact.c    Mon Sep 25 21:28:23 1989
  763. X***************
  764. X*** 15,24 ****
  765. X  
  766. X  { LONG_SWORD,     "Excalibur",    (SPFX_NOGEN | SPFX_SEEK | SPFX_DEFN |
  767. X                                  SPFX_SEARCH), 0,
  768. X!   { 0, AD_PHYS, 5, 10 }, { 0, AD_DRLI, 0, 0}, A_LAW },
  769. X  
  770. X  { KATANA,     "Snickersnee",    SPFX_RESTR, 0,
  771. X!   { 0, AD_PHYS, 0, 8 }, NO_ATTK, A_LAW },
  772. X  
  773. X  /*    Ah, never shall I forget the cry, 
  774. X   *        or the shriek that shrieked he,
  775. X--- 15,24 ----
  776. X  
  777. X  { LONG_SWORD,     "Excalibur",    (SPFX_NOGEN | SPFX_SEEK | SPFX_DEFN |
  778. X                                  SPFX_SEARCH), 0,
  779. X!   { 0, AD_PHYS, 5, 10 }, { 0, AD_DRLI, 0, 0}, A_LAW, 'K' },
  780. X  
  781. X  { KATANA,     "Snickersnee",    SPFX_RESTR, 0,
  782. X!   { 0, AD_PHYS, 0, 8 }, NO_ATTK, A_LAW, 'S' },
  783. X  
  784. X  /*    Ah, never shall I forget the cry, 
  785. X   *        or the shriek that shrieked he,
  786. X***************
  787. X*** 30,100 ****
  788. X   */
  789. X  
  790. X  { AXE,         "Cleaver",    SPFX_RESTR, 0,
  791. X!   { 0, AD_PHYS, 3, 12 }, NO_ATTK, A_CHAOS },
  792. X  
  793. X  #ifdef TOLKIEN
  794. X  { ORCISH_DAGGER, "Grimtooth",    SPFX_RESTR, 0,
  795. X!   { 0, AD_PHYS, 2, 6 }, NO_ATTK, A_CHAOS },
  796. X  #else
  797. X  { DAGGER,     "Grimtooth",    SPFX_RESTR, 0,
  798. X!   { 0, AD_PHYS, 2, 6 }, NO_ATTK, A_CHAOS },
  799. X  #endif
  800. X  
  801. X  /*  Special purpose swords - various types */
  802. X  
  803. X! { TWO_HANDED_SWORD, "Orcrist",    SPFX_DCLAS, S_ORC,
  804. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  805. X  
  806. X  #ifdef TOLKIEN
  807. X! { ELVEN_DAGGER,     "Sting",    (SPFX_WARN | SPFX_DCLAS), S_ORC,
  808. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  809. X  #else
  810. X! { DAGGER,     "Sting",    (SPFX_WARN | SPFX_DCLAS), S_ORC,
  811. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  812. X  #endif
  813. X  
  814. X  { LONG_SWORD,     "Frost Brand", (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0,
  815. X!   { 0, AD_COLD, 5, 0 }, { 0, AD_COLD, 0, 0 }, A_NEUTRAL },
  816. X  
  817. X  { LONG_SWORD,     "Fire Brand",    (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0,
  818. X!   { 0, AD_FIRE, 5, 0 }, { 0, AD_FIRE, 0, 0 }, A_NEUTRAL },
  819. X  
  820. X  /* Stormbringer only has a 2 because it can drain a level, providing 8 more */
  821. X  { BROADSWORD,     "Stormbringer", (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN |
  822. X                                  SPFX_DRLI), 0,
  823. X!   { 0, AD_DRLI, 5, 2 }, { 0, AD_DRLI, 0, 0 }, A_CHAOS },
  824. X  
  825. X! { LONG_SWORD,     "Sunsword",    (SPFX_RESTR | SPFX_DCLAS), 0, /* undead */
  826. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  827. X  
  828. X  { BROADSWORD,     "Dragonbane",    (SPFX_RESTR | SPFX_DCLAS), S_DRAGON,
  829. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_NEUTRAL },
  830. X  
  831. X! { LONG_SWORD,     "Demonbane",    (SPFX_RESTR | SPFX_DCLAS), 0, /* demons */
  832. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  833. X  
  834. X  /* A silver weapon would be appropriate, if we had one. */
  835. X! { LONG_SWORD,     "Werebane",    (SPFX_RESTR | SPFX_DCLAS), 0, /* weres */
  836. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  837. X  
  838. X! { LONG_SWORD,     "Giantslayer", (SPFX_RESTR | SPFX_DCLAS), 0, /* giants */
  839. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_NEUTRAL },
  840. X  
  841. X  /* Another interesting weapon would be the dwarven hammer or axe with the
  842. X   * boomerang-like power of returning to the wielder's hand, if the code
  843. X   * were written to add such an ability.
  844. X   */
  845. X! { WAR_HAMMER, "Ogresmasher",    (SPFX_RESTR | SPFX_DCLAS),  S_OGRE,
  846. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  847. X  
  848. X  { WAR_HAMMER, "Mjollnir",    (SPFX_RESTR | SPFX_ATTK),  0,
  849. X!   { 0, AD_ELEC, 5, 24 }, NO_ATTK, A_LAW }, /* Mjo:llnir */
  850. X  
  851. X  { MORNING_STAR,     "Trollsbane", (SPFX_RESTR | SPFX_DCLAS), S_TROLL,
  852. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW },
  853. X  
  854. X  /*    ARRAY TERMINATOR    */
  855. X! { 0,  "", 0, 0, NO_ATTK, NO_ATTK, 0 }
  856. X  };
  857. X  
  858. X  void
  859. X--- 30,100 ----
  860. X   */
  861. X  
  862. X  { AXE,         "Cleaver",    SPFX_RESTR, 0,
  863. X!   { 0, AD_PHYS, 3, 12 }, NO_ATTK, A_CHAOS, 0 },
  864. X  
  865. X  #ifdef TOLKIEN
  866. X  { ORCISH_DAGGER, "Grimtooth",    SPFX_RESTR, 0,
  867. X!   { 0, AD_PHYS, 2, 6 }, NO_ATTK, A_CHAOS, 0 },
  868. X  #else
  869. X  { DAGGER,     "Grimtooth",    SPFX_RESTR, 0,
  870. X!   { 0, AD_PHYS, 2, 6 }, NO_ATTK, A_CHAOS, 0 },
  871. X  #endif
  872. X  
  873. X  /*  Special purpose swords - various types */
  874. X  
  875. X! { TWO_HANDED_SWORD, "Orcrist",    SPFX_DFLAG2, M2_ORC,
  876. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 'E' },
  877. X  
  878. X  #ifdef TOLKIEN
  879. X! { ELVEN_DAGGER,     "Sting",    (SPFX_WARN | SPFX_DFLAG2), M2_ORC,
  880. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  881. X  #else
  882. X! { DAGGER,     "Sting",    (SPFX_WARN | SPFX_DFLAG2), M2_ORC,
  883. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  884. X  #endif
  885. X  
  886. X  { LONG_SWORD,     "Frost Brand", (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0,
  887. X!   { 0, AD_COLD, 5, 0 }, { 0, AD_COLD, 0, 0 }, A_NEUTRAL, 0 },
  888. X  
  889. X  { LONG_SWORD,     "Fire Brand",    (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN), 0,
  890. X!   { 0, AD_FIRE, 5, 0 }, { 0, AD_FIRE, 0, 0 }, A_NEUTRAL, 0 },
  891. X  
  892. X  /* Stormbringer only has a 2 because it can drain a level, providing 8 more */
  893. X  { BROADSWORD,     "Stormbringer", (SPFX_RESTR | SPFX_ATTK | SPFX_DEFN |
  894. X                                  SPFX_DRLI), 0,
  895. X!   { 0, AD_DRLI, 5, 2 }, { 0, AD_DRLI, 0, 0 }, A_CHAOS, 0 },
  896. X  
  897. X! { LONG_SWORD,     "Sunsword",    (SPFX_RESTR | SPFX_DFLAG1), M1_UNDEAD,
  898. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  899. X  
  900. X  { BROADSWORD,     "Dragonbane",    (SPFX_RESTR | SPFX_DCLAS), S_DRAGON,
  901. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_NEUTRAL, 0 },
  902. X  
  903. X! { LONG_SWORD,     "Demonbane",    (SPFX_RESTR | SPFX_DFLAG2), M2_DEMON,
  904. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  905. X  
  906. X  /* A silver weapon would be appropriate, if we had one. */
  907. X! { LONG_SWORD,     "Werebane",    (SPFX_RESTR | SPFX_DFLAG1), M1_WERE,
  908. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  909. X  
  910. X! { LONG_SWORD,     "Giantslayer", (SPFX_RESTR | SPFX_DFLAG2), M2_GIANT,
  911. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_NEUTRAL, 0 },
  912. X  
  913. X  /* Another interesting weapon would be the dwarven hammer or axe with the
  914. X   * boomerang-like power of returning to the wielder's hand, if the code
  915. X   * were written to add such an ability.
  916. X   */
  917. X! { WAR_HAMMER, "Ogresmasher",    (SPFX_RESTR | SPFX_DCLAS), S_OGRE,
  918. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  919. X  
  920. X  { WAR_HAMMER, "Mjollnir",    (SPFX_RESTR | SPFX_ATTK),  0,
  921. X!   { 0, AD_ELEC, 5, 24 }, NO_ATTK, A_LAW, 'V' }, /* Mjo:llnir */
  922. X  
  923. X  { MORNING_STAR,     "Trollsbane", (SPFX_RESTR | SPFX_DCLAS), S_TROLL,
  924. X!   { 0, AD_PHYS, 5, 0 }, NO_ATTK, A_LAW, 0 },
  925. X  
  926. X  /*    ARRAY TERMINATOR    */
  927. X! { 0,  "", 0, 0, NO_ATTK, NO_ATTK, 0, 0 }
  928. X  };
  929. X  
  930. X  void
  931. X***************
  932. X*** 177,183 ****
  933. X      register int n = 0;
  934. X  
  935. X      for(artif = artilist; artif->otyp; artif++)
  936. X!         if(align == artif->align && !(artif->spfx & SPFX_NOGEN)) n++;
  937. X      if (n) {
  938. X          n = rnd(n);
  939. X          for(artif = artilist; artif->otyp && n > 0; ) {
  940. X--- 177,186 ----
  941. X      register int n = 0;
  942. X  
  943. X      for(artif = artilist; artif->otyp; artif++)
  944. X!         if(align == artif->align && !(artif->spfx & SPFX_NOGEN))
  945. X!         if (pl_character[0] == artif->class) {
  946. X!             n=0; break;
  947. X!         } else n++;
  948. X      if (n) {
  949. X          n = rnd(n);
  950. X          for(artif = artilist; artif->otyp && n > 0; ) {
  951. X***************
  952. X*** 185,195 ****
  953. X              n--;
  954. X              if (n > 0) artif++;
  955. X          }
  956. X!         if(artif->otyp) {
  957. X!             otmp = mksobj((int)artif->otyp, FALSE);
  958. X!             otmp = oname(otmp, artif->name, 0);
  959. X!             return (otmp);
  960. X!         }
  961. X      }
  962. X      return ((struct obj *) 0);
  963. X  }
  964. X--- 188,198 ----
  965. X              n--;
  966. X              if (n > 0) artif++;
  967. X          }
  968. X!     }
  969. X!     if(artif->otyp) {
  970. X!         otmp = mksobj((int)artif->otyp, FALSE);
  971. X!         otmp = oname(otmp, artif->name, 0);
  972. X!         return (otmp);
  973. X      }
  974. X      return ((struct obj *) 0);
  975. X  }
  976. X***************
  977. X*** 212,239 ****
  978. X  register struct artifact *weap;
  979. X  struct permonst *ptr;
  980. X  {
  981. X!     if(!(weap->spfx & (SPFX_DMONS | SPFX_DCLAS | SPFX_ATTK)))
  982. X          return(1);
  983. X  
  984. X      if(weap->spfx & SPFX_DMONS)
  985. X!         return((ptr == &mons[weap->mtype]));
  986. X!     else if(weap->spfx & SPFX_DCLAS) {
  987. X! 
  988. X!         if(weap->mtype)
  989. X!         return((weap->mtype == ptr->mlet));
  990. X!         else {
  991. X!         if(!strcmp(weap->name, "Sunsword"))
  992. X!             return(is_undead(ptr));
  993. X!         else if(!strcmp(weap->name, "Demonbane"))
  994. X!             return(is_demon(ptr));
  995. X!         else if(!strcmp(weap->name, "Werebane"))
  996. X!             return(is_were(ptr));
  997. X!         else if(!strcmp(weap->name, "Giantslayer"))
  998. X!             return(is_giant(ptr));
  999. X!         else impossible("Weird class specific weapon '%s'",
  1000. X!                 weap->name);
  1001. X!         }
  1002. X!     } else if(weap->spfx & SPFX_ATTK) {
  1003. X          switch(weap->attk.adtyp) {
  1004. X          case AD_FIRE:    return(!resists_fire(ptr));
  1005. X          case AD_COLD:    return(!resists_cold(ptr));
  1006. X--- 215,232 ----
  1007. X  register struct artifact *weap;
  1008. X  struct permonst *ptr;
  1009. X  {
  1010. X!     if(!(weap->spfx & (SPFX_DBONUS | SPFX_ATTK)))
  1011. X          return(1);
  1012. X  
  1013. X      if(weap->spfx & SPFX_DMONS)
  1014. X!         return((ptr == &mons[(int)weap->mtype]));
  1015. X!     else if(weap->spfx & SPFX_DCLAS)
  1016. X!         return((weap->mtype == ptr->mlet));
  1017. X!     else if(weap->spfx & SPFX_DFLAG1)
  1018. X!         return((ptr->mflags1 & weap->mtype) != 0L);
  1019. X!     else if(weap->spfx & SPFX_DFLAG2)
  1020. X!         return((ptr->mflags2 & weap->mtype) != 0L);
  1021. X!     else if(weap->spfx & SPFX_ATTK) {
  1022. X          switch(weap->attk.adtyp) {
  1023. X          case AD_FIRE:    return(!resists_fire(ptr));
  1024. X          case AD_COLD:    return(!resists_cold(ptr));
  1025. X*** src/Old/attrib.c    Wed Sep 27 11:19:13 1989
  1026. X--- src/attrib.c    Mon Sep 25 21:29:23 1989
  1027. X***************
  1028. X*** 88,94 ****
  1029. X      struct    attribs    base, dist;
  1030. X       schar    align, aligntyp;
  1031. X      schar    shp, hd, xlev, ndx;
  1032. X! /* According to AD&D, HD for some classes (i.e. Wizard) should be smaller
  1033. X   * (4-sided for wizards).  But this is not AD&D, and using the AD&D
  1034. X   * rule here produces an unplayable character.  This I have used a minimum
  1035. X   * of an 10-sided hit die for everything.  Another AD&D change: wizards get
  1036. X--- 88,94 ----
  1037. X      struct    attribs    base, dist;
  1038. X       schar    align, aligntyp;
  1039. X      schar    shp, hd, xlev, ndx;
  1040. X! /* According to AD&D, HD for some classes (ex. Wizard) should be smaller
  1041. X   * (4-sided for wizards).  But this is not AD&D, and using the AD&D
  1042. X   * rule here produces an unplayable character.  This I have used a minimum
  1043. X   * of an 10-sided hit die for everything.  Another AD&D change: wizards get
  1044. X*** src/Old/bones.c    Wed Sep 27 11:19:32 1989
  1045. X--- src/bones.c    Tue Sep 26 16:08:32 1989
  1046. X***************
  1047. X*** 16,22 ****
  1048. X  extern long bytes_counted;
  1049. X  #endif
  1050. X  #else
  1051. X! char bones[] = "bones.xx";
  1052. X  #endif
  1053. X  
  1054. X  #ifdef COMPRESS
  1055. X--- 16,22 ----
  1056. X  extern long bytes_counted;
  1057. X  #endif
  1058. X  #else
  1059. X! char bones[] = "bones.xxxx";
  1060. X  #endif
  1061. X  
  1062. X  #ifdef COMPRESS
  1063. X***************
  1064. X*** 130,135 ****
  1065. X--- 130,138 ----
  1066. X      for(f=ffruit; f; f=f->nextf) f->fid = -f->fid;
  1067. X  #endif
  1068. X  
  1069. X+     /* check iron balls separately--maybe they're not carrying it */
  1070. X+     if (uball) uball->owornmask = uchain->owornmask = 0;
  1071. X+ 
  1072. X      /* drop everything; the corpse's possessions are usually cursed */
  1073. X      otmp = invent;
  1074. X      while(otmp) {
  1075. X***************
  1076. X*** 177,183 ****
  1077. X  #ifdef TUTTI_FRUTTI
  1078. X              if(otmp->otyp == SLIME_MOLD) goodfruit(otmp->spe);
  1079. X  #endif
  1080. X!             if(uses_known(otmp)) otmp->known = 0;
  1081. X              if(otmp->otyp == AMULET_OF_YENDOR && !otmp->spe) {
  1082. X              otmp->spe = -1;  /* no longer the actual amulet */
  1083. X              curse(otmp);
  1084. X--- 180,186 ----
  1085. X  #ifdef TUTTI_FRUTTI
  1086. X              if(otmp->otyp == SLIME_MOLD) goodfruit(otmp->spe);
  1087. X  #endif
  1088. X!             if(objects[otmp->otyp].oc_uses_known) otmp->known = 0;
  1089. X              if(otmp->otyp == AMULET_OF_YENDOR && !otmp->spe) {
  1090. X              otmp->spe = -1;  /* no longer the actual amulet */
  1091. X              curse(otmp);
  1092. X***************
  1093. X*** 201,207 ****
  1094. X  #endif
  1095. X             )
  1096. X              otmp->onamelth = 0;
  1097. X!         if(uses_known(otmp)) otmp->known = 0;
  1098. X  #ifdef TUTTI_FRUTTI
  1099. X          if(otmp->otyp == SLIME_MOLD) goodfruit(otmp->spe);
  1100. X  #endif
  1101. X--- 204,210 ----
  1102. X  #endif
  1103. X             )
  1104. X              otmp->onamelth = 0;
  1105. X!         if(objects[otmp->otyp].oc_uses_known) otmp->known = 0;
  1106. X  #ifdef TUTTI_FRUTTI
  1107. X          if(otmp->otyp == SLIME_MOLD) goodfruit(otmp->spe);
  1108. X  #endif
  1109. X***************
  1110. X*** 355,371 ****
  1111. X   * but be careful if you use it for other things -dgk
  1112. X   */
  1113. X  void
  1114. X! name_file(file, level)
  1115. X  char *file;
  1116. X! int level;
  1117. X  {
  1118. X      char *tf;
  1119. X  
  1120. X      if (tf = rindex(file, '.'))
  1121. X!         Sprintf(tf+1, "%d", level);
  1122. X  #ifdef MSDOS /* for glo() */
  1123. X      else if (tf = eos(file))
  1124. X!         Sprintf(tf, ".%d", level);
  1125. X  #endif
  1126. X      return;
  1127. X  }
  1128. X--- 358,378 ----
  1129. X   * but be careful if you use it for other things -dgk
  1130. X   */
  1131. X  void
  1132. X! name_file(file, lev)
  1133. X  char *file;
  1134. X! int lev;
  1135. X  {
  1136. X      char *tf;
  1137. X  
  1138. X      if (tf = rindex(file, '.'))
  1139. X! #ifdef VMS
  1140. X!         Sprintf(tf+1, "%d;1", lev);
  1141. X! #else
  1142. X!           Sprintf(tf+1, "%d", lev);
  1143. X! #endif
  1144. X  #ifdef MSDOS /* for glo() */
  1145. X      else if (tf = eos(file))
  1146. X!         Sprintf(tf, ".%d", lev);
  1147. X  #endif
  1148. X      return;
  1149. X  }
  1150. X*** src/Old/cmd.c    Wed Sep 27 11:19:52 1989
  1151. X--- src/cmd.c    Mon Sep 25 22:55:13 1989
  1152. X***************
  1153. X*** 348,353 ****
  1154. X--- 348,354 ----
  1155. X  
  1156. X  void
  1157. X  enlightenment() {
  1158. X+     char buf[BUFSZ];
  1159. X  
  1160. X      cornline(0, "Current Attributes:");
  1161. X  
  1162. X***************
  1163. X*** 355,360 ****
  1164. X--- 356,367 ----
  1165. X      else if (u.ualign > 3) cornline(1, "You are stridently aligned.");
  1166. X      else if (u.ualign > 0) cornline(1, "You are haltingly aligned.");
  1167. X      else cornline(1, "You have strayed.");
  1168. X+ #ifdef WIZARD
  1169. X+     if (wizard) {
  1170. X+         Sprintf(buf, "Your alignment is %d.", u.ualign);
  1171. X+         cornline(1, buf);
  1172. X+     }
  1173. X+ #endif
  1174. X  
  1175. X      if (Adornment) cornline(1, "You are adorned.");
  1176. X      if (Teleportation) cornline(1, "You can teleport.");
  1177. X***************
  1178. X*** 388,395 ****
  1179. X      if (Invisible) cornline(1, "You are invisible.");
  1180. X      else if (Invis) cornline(1, "You are invisible to others.");
  1181. X      if (Wounded_legs) {
  1182. X-         char buf[41];
  1183. X- 
  1184. X          Sprintf(buf, "You have wounded %s.",
  1185. X                          makeplural(body_part(LEG)));
  1186. X          cornline(1, buf);
  1187. X--- 395,400 ----
  1188. X***************
  1189. X*** 397,404 ****
  1190. X      if (Stoned) cornline(1, "You are turning to stone.");
  1191. X      /* if (Hallucination) cornline(1, "You are hallucinating."); */
  1192. X      if (Glib) {
  1193. X-         char buf[41];
  1194. X- 
  1195. X          Sprintf(buf, "You have slippery %s.",
  1196. X                          makeplural(body_part(FINGER)));
  1197. X          cornline(1, buf);
  1198. X--- 402,407 ----
  1199. X***************
  1200. X*** 420,425 ****
  1201. X--- 423,434 ----
  1202. X          if (stone_luck(FALSE) >= 0)
  1203. X              cornline(1, "Good luck does not time out for you.");
  1204. X      }
  1205. X+ #ifdef WIZARD
  1206. X+     if (wizard) {
  1207. X+         Sprintf(buf, "Your luck is %d.", u.uluck);
  1208. X+         cornline(1, buf);
  1209. X+     }
  1210. X+ #endif
  1211. X  
  1212. X      cornline(2, "");
  1213. X      return;
  1214. X*** src/Old/dbridge.c    Wed Sep 27 11:20:19 1989
  1215. X--- src/dbridge.c    Thu Sep 14 14:12:30 1989
  1216. X***************
  1217. X*** 222,228 ****
  1218. X      }
  1219. X      lev2->diggable = (W_NONDIGGABLE | W_GATEWAY);
  1220. X      if ((lev1->drawbridgemask & DB_UNDER) == DB_MOAT) {
  1221. X!         if (lev1->mmask && !is_flyer((mtmp = m_at(x,y))->data)) {
  1222. X          if (is_swimmer(mtmp->data)) {
  1223. X              if (flags.soundok) You("hear a splash.");
  1224. X          } else {
  1225. X--- 222,228 ----
  1226. X      }
  1227. X      lev2->diggable = (W_NONDIGGABLE | W_GATEWAY);
  1228. X      if ((lev1->drawbridgemask & DB_UNDER) == DB_MOAT) {
  1229. X!         if (MON_AT(x, y) && !is_flyer((mtmp = m_at(x,y))->data)) {
  1230. X          if (is_swimmer(mtmp->data)) {
  1231. X              if (flags.soundok) You("hear a splash.");
  1232. X          } else {
  1233. X***************
  1234. X*** 244,250 ****
  1235. X              if (!Wwalking) drown();
  1236. X          }
  1237. X      }
  1238. X!     if (lev2->mmask && !noncorporeal((mtmp = m_at(x2, y2))->data)) {
  1239. X          if (cansee(x2,y2))
  1240. X              pline("%s is crushed by the portcullis.",Monnam(mtmp));
  1241. X          else if (flags.soundok)
  1242. X--- 244,250 ----
  1243. X              if (!Wwalking) drown();
  1244. X          }
  1245. X      }
  1246. X!     if (MON_AT(x2,y2) && !noncorporeal((mtmp = m_at(x2, y2))->data)) {
  1247. X          if (cansee(x2,y2))
  1248. X              pline("%s is crushed by the portcullis.",Monnam(mtmp));
  1249. X          else if (flags.soundok)
  1250. X*** src/Old/decl.c    Wed Sep 27 11:20:37 1989
  1251. X--- src/decl.c    Tue Sep 26 12:59:05 1989
  1252. X***************
  1253. X*** 72,78 ****
  1254. X  int CO = 0, LI = 0;    /* set up in termcap.c: usually COLNO and ROWNO+3 */
  1255. X  
  1256. X  #ifdef TEXTCOLOR
  1257. X! char *HI_COLOR[8];        /* terminal escapes for the various colors */
  1258. X  #endif
  1259. X  
  1260. X  #ifdef MSDOS
  1261. X--- 72,78 ----
  1262. X  int CO = 0, LI = 0;    /* set up in termcap.c: usually COLNO and ROWNO+3 */
  1263. X  
  1264. X  #ifdef TEXTCOLOR
  1265. X! char *hilites[MAXCOLORS];    /* terminal escapes for the various colors */
  1266. X  #endif
  1267. X  
  1268. X  #ifdef MSDOS
  1269. X***************
  1270. X*** 89,95 ****
  1271. X  const char *alllevels = "levels.*";
  1272. X  const char *allbones = "bones.*";
  1273. X  #else
  1274. X! char lock[PL_NSIZ+4] = "1lock";    /* long enough for login name .99 */
  1275. X  #endif
  1276. X  
  1277. X  int dig_effort = 0;    /* effort expended on current pos */
  1278. X--- 89,99 ----
  1279. X  const char *alllevels = "levels.*";
  1280. X  const char *allbones = "bones.*";
  1281. X  #else
  1282. X! # ifdef VMS
  1283. X! char lock[PL_NSIZ+16] = "1lock";/* long enough for uic+login_name+.99;1 */
  1284. X! # else
  1285. X! char lock[PL_NSIZ+14] = "1lock";/* long enough for uic+login_name+.99 */
  1286. X! # endif
  1287. X  #endif
  1288. X  
  1289. X  int dig_effort = 0;    /* effort expended on current pos */
  1290. X***************
  1291. X*** 125,132 ****
  1292. X  coord doors[DOORMAX] = DUMMY;
  1293. X  
  1294. X  struct mkroom rooms[MAXNROFROOMS+1] = DUMMY;
  1295. X! struct rm levl[COLNO][ROWNO] = DUMMY;        /* level map */
  1296. X! struct monst *fmon = 0;
  1297. X  struct trap *ftrap = 0;
  1298. X  struct gold *fgold = 0;
  1299. X  struct monst youmonst = DUMMY;    /* dummy; used as return value for boomhit */
  1300. X--- 129,135 ----
  1301. X  coord doors[DOORMAX] = DUMMY;
  1302. X  
  1303. X  struct mkroom rooms[MAXNROFROOMS+1] = DUMMY;
  1304. X! level_t level;        /* level map */
  1305. X  struct trap *ftrap = 0;
  1306. X  struct gold *fgold = 0;
  1307. X  struct monst youmonst = DUMMY;    /* dummy; used as return value for boomhit */
  1308. X***************
  1309. X*** 133,139 ****
  1310. X  struct flag flags = DUMMY;
  1311. X  struct you u = DUMMY;
  1312. X  
  1313. X! struct obj *fobj = 0, *fcobj = 0, *invent = 0, *uwep = 0, *uarm = 0,
  1314. X  #ifdef SHIRT
  1315. X      *uarmu = 0,        /* under-wear, so to speak */
  1316. X  #endif
  1317. X--- 136,142 ----
  1318. X  struct flag flags = DUMMY;
  1319. X  struct you u = DUMMY;
  1320. X  
  1321. X! struct obj *fcobj = 0, *invent = 0, *uwep = 0, *uarm = 0,
  1322. X  #ifdef SHIRT
  1323. X      *uarmu = 0,        /* under-wear, so to speak */
  1324. X  #endif
  1325. X***************
  1326. X*** 186,192 ****
  1327. X  struct spell spl_book[MAXSPELL + 1] = DUMMY;
  1328. X  #endif
  1329. X  
  1330. X! long moves = 1;
  1331. X  long wailmsg = 0;
  1332. X  
  1333. X  struct obj zeroobj = DUMMY;    /* used to zero all elements of a struct obj */
  1334. X--- 189,195 ----
  1335. X  struct spell spl_book[MAXSPELL + 1] = DUMMY;
  1336. X  #endif
  1337. X  
  1338. X! long moves = 1, monstermoves = 1; /* These diverge when player is Fast */
  1339. X  long wailmsg = 0;
  1340. X  
  1341. X  struct obj zeroobj = DUMMY;    /* used to zero all elements of a struct obj */
  1342. X*** src/Old/demon.c    Wed Sep 27 11:20:53 1989
  1343. X--- src/demon.c    Mon Sep 25 21:29:25 1989
  1344. X***************
  1345. X*** 84,91 ****
  1346. X          return mtmp->mpeaceful = 0;
  1347. X      else {
  1348. X  
  1349. X!         pline("%s demands %ld Zorkmids for safe passage.",
  1350. X!           Xmonnam(mtmp), demand);
  1351. X  
  1352. X          if((offer = bribe(mtmp)) >= demand) {
  1353. X          pline("%s vanishes laughing about cowardly mortals.",
  1354. X--- 84,91 ----
  1355. X          return mtmp->mpeaceful = 0;
  1356. X      else {
  1357. X  
  1358. X!         pline("%s demands %ld zorkmid%s for safe passage.",
  1359. X!           Xmonnam(mtmp), demand, plur(demand));
  1360. X  
  1361. X          if((offer = bribe(mtmp)) >= demand) {
  1362. X          pline("%s vanishes laughing about cowardly mortals.",
  1363. X***************
  1364. X*** 127,134 ****
  1365. X       } else if(offer >= u.ugold) {
  1366. X          You("give %s all your gold.", x_monnam(mtmp, 0));
  1367. X          offer = u.ugold;
  1368. X!     } else You("give %s %ld Zorkmid%s.", x_monnam(mtmp, 0), offer,
  1369. X!            offer == 1 ? "" : "s");
  1370. X  
  1371. X      u.ugold -= offer;
  1372. X      return(offer);
  1373. X--- 127,134 ----
  1374. X       } else if(offer >= u.ugold) {
  1375. X          You("give %s all your gold.", x_monnam(mtmp, 0));
  1376. X          offer = u.ugold;
  1377. X!     } else You("give %s %ld zorkmid%s.", x_monnam(mtmp, 0), offer,
  1378. X!            plur(offer));
  1379. X  
  1380. X      u.ugold -= offer;
  1381. X      return(offer);
  1382. X*** src/Old/do.c    Wed Sep 27 11:21:10 1989
  1383. X--- src/do.c    Mon Sep 25 22:57:35 1989
  1384. X***************
  1385. X*** 30,47 ****
  1386. X  struct obj *obj;
  1387. X  int x,y;
  1388. X  {
  1389. X!     if(obj->otyp == BOULDER && IS_POOL(levl[x][y].typ)) {
  1390. X  #ifdef STRONGHOLD
  1391. X!         if(levl[x][y].typ == DRAWBRIDGE_UP)
  1392. X!         levl[x][y].drawbridgemask |= DB_FLOOR;
  1393. X!         else
  1394. X  #endif
  1395. X!         levl[x][y].typ = ROOM;
  1396. X!         if (cansee(x,y))
  1397. X!         pline("There is a large splash as the boulder fills the %s.",
  1398. X              (levl[x][y].typ==POOL) ? "pool" : "moat");
  1399. X!         else if (flags.soundok)
  1400. X!         You("hear a splash.");
  1401. X          obfree(obj, (struct obj *)0);
  1402. X          mnewsym(x,y);
  1403. X          if ((x != u.ux || y != u.uy || Invisible) && !Blind)
  1404. X--- 30,75 ----
  1405. X  struct obj *obj;
  1406. X  int x,y;
  1407. X  {
  1408. X!     struct trap *t = t_at(x,y);
  1409. X!     boolean pool = IS_POOL(levl[x][y].typ);
  1410. X! 
  1411. X!     if(obj->otyp == BOULDER && (pool ||
  1412. X!       (t && (t->ttyp==PIT || t->ttyp==SPIKED_PIT || t->ttyp==TRAPDOOR)))) {
  1413. X!         if (pool) {
  1414. X  #ifdef STRONGHOLD
  1415. X!         if(levl[x][y].typ == DRAWBRIDGE_UP)
  1416. X!             levl[x][y].drawbridgemask |= DB_FLOOR;
  1417. X!         else
  1418. X  #endif
  1419. X!             levl[x][y].typ = ROOM;
  1420. X!         if (cansee(x,y))
  1421. X!           pline("There is a large splash as the boulder fills the %s.",
  1422. X              (levl[x][y].typ==POOL) ? "pool" : "moat");
  1423. X!         else if (flags.soundok)
  1424. X!             You("hear a splash.");
  1425. X!         } else if (t) {
  1426. X!         if(is_maze_lev
  1427. X! #ifdef STRONGHOLD
  1428. X!              && (dlevel > stronghold_level)
  1429. X! #endif
  1430. X!             && t->ttyp == TRAPDOOR) return FALSE;
  1431. X!         if (Blind) You("hear the boulder roll.");
  1432. X!         else pline("The boulder %sfills a %s.",
  1433. X!             t->tseen ? "" : "triggers and ",
  1434. X!             t->ttyp == TRAPDOOR ? "trapdoor" : "pit");
  1435. X!         deltrap(t);
  1436. X!         if (u.utrap && x==u.ux && y==u.uy) {
  1437. X!             u.utrap = 0;
  1438. X! #ifdef POLYSELF
  1439. X!             if (!passes_walls(uasmon)) {
  1440. X! #endif
  1441. X!             pline("Unfortunately, you were still in it.");
  1442. X!             losehp(rnd(15), "burial beneath a boulder");
  1443. X! #ifdef POLYSELF
  1444. X!             }
  1445. X! #endif
  1446. X!         }
  1447. X!         }
  1448. X          obfree(obj, (struct obj *)0);
  1449. X          mnewsym(x,y);
  1450. X          if ((x != u.ux || y != u.uy || Invisible) && !Blind)
  1451. X***************
  1452. X*** 225,231 ****
  1453. X          obj->bknown = 1;
  1454. X          pline("For some reason, you cannot %s the stone%s!",
  1455. X              word,
  1456. X!             obj->quan==1 ? "" : "s");
  1457. X          return(FALSE);
  1458. X      }
  1459. X  #ifdef WALKIES
  1460. X--- 253,259 ----
  1461. X          obj->bknown = 1;
  1462. X          pline("For some reason, you cannot %s the stone%s!",
  1463. X              word,
  1464. X!             plur((long)obj->quan));
  1465. X          return(FALSE);
  1466. X      }
  1467. X  #ifdef WALKIES
  1468. X***************
  1469. X*** 322,328 ****
  1470. X          fobj = obj;
  1471. X          place_object(obj, u.ux, u.uy);
  1472. X          if(Invisible) newsym(u.ux,u.uy);
  1473. X!         if(obj != uball) subfrombill(obj);
  1474. X          stackobj(obj);
  1475. X      }
  1476. X  }
  1477. X--- 350,356 ----
  1478. X          fobj = obj;
  1479. X          place_object(obj, u.ux, u.uy);
  1480. X          if(Invisible) newsym(u.ux,u.uy);
  1481. X!         if(obj != uball) sellobj(obj);
  1482. X          stackobj(obj);
  1483. X      }
  1484. X  }
  1485. X***************
  1486. X*** 348,353 ****
  1487. X--- 376,386 ----
  1488. X  #endif
  1489. X        ) {
  1490. X          if (!(trap = t_at(u.ux,u.uy)) || trap->ttyp != TRAPDOOR
  1491. X+             || (is_maze_lev
  1492. X+ #ifdef STRONGHOLD
  1493. X+                 && (dlevel > stronghold_level)
  1494. X+ #endif
  1495. X+                                 )
  1496. X                              || !trap->tseen) {
  1497. X              You("can't go down here.");
  1498. X              return(0);
  1499. X***************
  1500. X*** 404,410 ****
  1501. X--- 437,450 ----
  1502. X          You("are being held, and cannot go up.");
  1503. X          return(1);
  1504. X      }
  1505. X+ #ifdef POLYSELF
  1506. X+     /* Some monsters have carrying capacities less than 5, and we don't
  1507. X+      * want to totally keep them from going upstairs.
  1508. X+      */
  1509. X+     if((invent || u.ugold) && inv_weight() + 5 > 0) {
  1510. X+ #else
  1511. X      if(inv_weight() + 5 > 0) {
  1512. X+ #endif
  1513. X          /* No levitation check; inv_weight() already allows for it */
  1514. X  #ifdef STRONGHOLD
  1515. X          Your("load is too heavy to climb the %s.",
  1516. X***************
  1517. X*** 700,706 ****
  1518. X          u.ux = rnd(COLNO-1);
  1519. X          u.uy = rn2(ROWNO);
  1520. X          } while(tryct++ < 100 && (levl[u.ux][u.uy].typ != ROOM &&
  1521. X!              levl[u.ux][u.uy].typ != CORR) || levl[u.ux][u.uy].mmask);
  1522. X          if(tryct >= 100)
  1523. X          panic("goto_level: could not relocate player!");
  1524. X          if(Punished){
  1525. X--- 740,746 ----
  1526. X          u.ux = rnd(COLNO-1);
  1527. X          u.uy = rn2(ROWNO);
  1528. X          } while(tryct++ < 100 && (levl[u.ux][u.uy].typ != ROOM &&
  1529. X!              levl[u.ux][u.uy].typ != CORR) || MON_AT(u.ux, u.uy));
  1530. X          if(tryct >= 100)
  1531. X          panic("goto_level: could not relocate player!");
  1532. X          if(Punished){
  1533. X***************
  1534. X*** 719,725 ****
  1535. X      initrack();
  1536. X  
  1537. X      losedogs();
  1538. X!     if(levl[u.ux][u.uy].mmask) mnexto(m_at(u.ux, u.uy));
  1539. X      flags.nscrinh = 0;
  1540. X      setsee();
  1541. X      seeobjs();    /* make old cadavers disappear - riv05!a3 */
  1542. X--- 759,765 ----
  1543. X      initrack();
  1544. X  
  1545. X      losedogs();
  1546. X!     if(MON_AT(u.ux, u.uy)) mnexto(m_at(u.ux, u.uy));
  1547. X      flags.nscrinh = 0;
  1548. X      setsee();
  1549. X      seeobjs();    /* make old cadavers disappear - riv05!a3 */
  1550. X***************
  1551. X*** 732,738 ****
  1552. X      if (dlevel == 1 && u.uhave_amulet && flags.no_of_wizards == 0)
  1553. X          resurrect();
  1554. X  #endif
  1555. X!     is_maze_lev = !xdnstair;
  1556. X  }
  1557. X  
  1558. X  int
  1559. X--- 772,786 ----
  1560. X      if (dlevel == 1 && u.uhave_amulet && flags.no_of_wizards == 0)
  1561. X          resurrect();
  1562. X  #endif
  1563. X!     is_maze_lev = (rooms[0].hx < 0
  1564. X! #ifdef STRONGHOLD
  1565. X!         || dlevel == stronghold_level
  1566. X!         || (dlevel >= tower_level && dlevel <= tower_level + 2)
  1567. X! #endif
  1568. X! #ifdef ENDGAME
  1569. X!         || dlevel == ENDLEVEL
  1570. X! #endif
  1571. X!         );
  1572. X  }
  1573. X  
  1574. X  int
  1575. X***************
  1576. X*** 789,795 ****
  1577. X      obj->owt = weight(obj);
  1578. X      otmp->quan -= num;
  1579. X      otmp->owt = weight(otmp);    /* -= obj->owt ? */
  1580. X!     obj->nobj = otmp;
  1581. X      if(obj->unpaid) splitbill(obj,otmp);
  1582. X      return(otmp);
  1583. X  }
  1584. X--- 837,843 ----
  1585. X      obj->owt = weight(obj);
  1586. X      otmp->quan -= num;
  1587. X      otmp->owt = weight(otmp);    /* -= obj->owt ? */
  1588. X!     obj->nobj = obj->nexthere = otmp;
  1589. X      if(obj->unpaid) splitbill(obj,otmp);
  1590. X      return(otmp);
  1591. X  }
  1592. X***************
  1593. X*** 799,805 ****
  1594. X  register long side;
  1595. X  register int timex;
  1596. X  {
  1597. X!     if(!Wounded_legs) ATEMP(A_DEX)--;
  1598. X  
  1599. X      if(!Wounded_legs || (Wounded_legs & TIMEOUT))
  1600. X          Wounded_legs |= side + timex;
  1601. X--- 847,856 ----
  1602. X  register long side;
  1603. X  register int timex;
  1604. X  {
  1605. X!     if(!Wounded_legs) {
  1606. X!         ATEMP(A_DEX)--;
  1607. X!         flags.botl = 1;
  1608. X!     }
  1609. X  
  1610. X      if(!Wounded_legs || (Wounded_legs & TIMEOUT))
  1611. X          Wounded_legs |= side + timex;
  1612. X*** src/Old/do_name.c    Wed Sep 27 11:21:40 1989
  1613. X--- src/do_name.c    Sat Sep 23 00:46:41 1989
  1614. X***************
  1615. X*** 93,100 ****
  1616. X          plname);
  1617. X          return(0);
  1618. X      }
  1619. X!     if (!cansee(cx, cy) || !levl[cx][cy].mmask ||
  1620. X!         (mtmp = m_at(cx, cy))->mimic) {
  1621. X          pline("I see no monster there.");
  1622. X          return(0);
  1623. X      }
  1624. X--- 93,100 ----
  1625. X          plname);
  1626. X          return(0);
  1627. X      }
  1628. X!     if (!cansee(cx,cy) || !MON_AT(cx,cy) || (mtmp = m_at(cx, cy))->mimic
  1629. X!             || (mtmp->minvis && !See_invisible) || mtmp->mundetected) {
  1630. X          pline("I see no monster there.");
  1631. X          return(0);
  1632. X      }
  1633. X*** src/Old/do_wear.c    Wed Sep 27 11:22:02 1989
  1634. X--- src/do_wear.c    Sat Sep 16 17:53:44 1989
  1635. X***************
  1636. X*** 241,247 ****
  1637. X          }
  1638. X          break;
  1639. X      case HELM_OF_OPPOSITE_ALIGNMENT:
  1640. X!         if (u.ualigntyp == U_NEUTRAL) u.ualigntyp = rnd(2) ? -1 : 1;
  1641. X          else u.ualigntyp = -(u.ualigntyp);
  1642. X          makeknown(uarmh->otyp);
  1643. X          flags.botl = 1;
  1644. X--- 241,247 ----
  1645. X          }
  1646. X          break;
  1647. X      case HELM_OF_OPPOSITE_ALIGNMENT:
  1648. X!         if (u.ualigntyp == U_NEUTRAL) u.ualigntyp = rn2(2) ? -1 : 1;
  1649. X          else u.ualigntyp = -(u.ualigntyp);
  1650. X          makeknown(uarmh->otyp);
  1651. X          flags.botl = 1;
  1652. X***************
  1653. X*** 446,453 ****
  1654. X--- 446,459 ----
  1655. X          }
  1656. X          flags.botl = 1;
  1657. X          (void)strncpy(plname, buf, sizeof(plname)-1);
  1658. X+ #ifdef VMS
  1659. X+         Sprintf(SAVEF, "[.save]%d%s", getuid(), plname);
  1660. X+         regularize(SAVEF+7);
  1661. X+         Strcat(SAVEF, ";1");
  1662. X+ #else
  1663. X          Sprintf(SAVEF, "save/%d%s", getuid(), plname);
  1664. X          regularize(SAVEF+5);        /* avoid . or / in name */
  1665. X+ #endif
  1666. X  #ifdef WIZARD
  1667. X          }
  1668. X  #endif
  1669. X*** src/Old/dog.c    Wed Sep 27 11:22:53 1989
  1670. X--- src/dog.c    Thu Sep 14 14:18:20 1989
  1671. X***************
  1672. X*** 185,191 ****
  1673. X              continue;
  1674. X          }
  1675. X          relmon(mtmp);
  1676. X!         mtmp->mx = mtmp->my = 0; /* to avoid mnexto()/mmask problem */
  1677. X          mtmp->nmon = mydogs;
  1678. X          mydogs = mtmp;
  1679. X          unpmon(mtmp);
  1680. X--- 185,191 ----
  1681. X              continue;
  1682. X          }
  1683. X          relmon(mtmp);
  1684. X!         mtmp->mx = mtmp->my = 0; /* avoid mnexto()/MON_AT() problem */
  1685. X          mtmp->nmon = mydogs;
  1686. X          mydogs = mtmp;
  1687. X          unpmon(mtmp);
  1688. X***************
  1689. X*** 213,219 ****
  1690. X      mtmp->mx = tolev; 
  1691. X      mtmp->my = 0;
  1692. X          /* make sure to reset mtmp->mx to 0 when releasing, */
  1693. X!         /* so rloc() on next level doesn't affect mmask */
  1694. X  }
  1695. X  
  1696. X  /* return quality of food; the lower the better */
  1697. X--- 213,219 ----
  1698. X      mtmp->mx = tolev; 
  1699. X      mtmp->my = 0;
  1700. X          /* make sure to reset mtmp->mx to 0 when releasing, */
  1701. X!         /* so rloc() on next level doesn't affect MON_AT() state */
  1702. X  }
  1703. X  
  1704. X  /* return quality of food; the lower the better */
  1705. X*** src/Old/dogmove.c    Wed Sep 27 11:23:12 1989
  1706. X--- src/dogmove.c    Fri Sep 15 11:34:42 1989
  1707. X***************
  1708. X*** 81,87 ****
  1709. X              edog->droptime = moves;
  1710. X          }
  1711. X      } else {
  1712. X!         if(obj = o_at(omx,omy)) if(!index(nofetch, obj->olet)){
  1713. X              if((otyp = dogfood(mtmp, obj)) <= CADAVER){
  1714. X              nix = omx;
  1715. X              niy = omy;
  1716. X--- 81,87 ----
  1717. X              edog->droptime = moves;
  1718. X          }
  1719. X      } else {
  1720. X!         if((obj=level.objects[omx][omy]) && !index(nofetch,obj->olet)){
  1721. X              if((otyp = dogfood(mtmp, obj)) <= CADAVER){
  1722. X              nix = omx;
  1723. X              niy = omy;
  1724. X***************
  1725. X*** 211,217 ****
  1726. X          if(dist(nx, ny) > 4 && mtmp->mleashed) continue;
  1727. X  #endif
  1728. X          if(info[i] & ALLOW_M) {
  1729. X!             if(levl[nx][ny].mmask) {
  1730. X                  register struct monst *mtmp2 = m_at(nx,ny);
  1731. X  
  1732. X                  if(mtmp2->m_lev >= mtmp->m_lev+2 ||
  1733. X--- 211,217 ----
  1734. X          if(dist(nx, ny) > 4 && mtmp->mleashed) continue;
  1735. X  #endif
  1736. X          if(info[i] & ALLOW_M) {
  1737. X!             if(MON_AT(nx, ny)) {
  1738. X                  register struct monst *mtmp2 = m_at(nx,ny);
  1739. X  
  1740. X                  if(mtmp2->m_lev >= mtmp->m_lev+2 ||
  1741. X***************
  1742. X*** 318,327 ****
  1743. X              (void) mattacku(mtmp);
  1744. X              return(0);
  1745. X          }
  1746. X!         levl[omx][omy].mmask = 0;
  1747. X!         levl[nix][niy].mmask = 1;
  1748. X!         mtmp->mx = nix;
  1749. X!         mtmp->my = niy;
  1750. X          for(j=MTSZ-1; j>0; j--) mtmp->mtrack[j] = mtmp->mtrack[j-1];
  1751. X          mtmp->mtrack[0].x = omx;
  1752. X          mtmp->mtrack[0].y = omy;
  1753. X--- 318,325 ----
  1754. X              (void) mattacku(mtmp);
  1755. X              return(0);
  1756. X          }
  1757. X!         remove_monster(omx, omy);
  1758. X!         place_monster(mtmp, nix, niy);
  1759. X          for(j=MTSZ-1; j>0; j--) mtmp->mtrack[j] = mtmp->mtrack[j-1];
  1760. X          mtmp->mtrack[0].x = omx;
  1761. X          mtmp->mtrack[0].y = omy;
  1762. X***************
  1763. X*** 350,366 ****
  1764. X          cc.x = mtmp->mx;
  1765. X          cc.y = mtmp->my;
  1766. X  dognext:
  1767. X!         levl[mtmp->mx][mtmp->my].mmask = 0;
  1768. X!         levl[cc.x][cc.y].mmask = 1;
  1769. X!         mtmp->mx = cc.x;
  1770. X!         mtmp->my = cc.y;
  1771. X          pmon(mtmp);
  1772. X          set_apparxy(mtmp);
  1773. X      }
  1774. X  #endif
  1775. X- 
  1776. X-     if(mintrap(mtmp) == 2)        /* he died */
  1777. X-         return(2);
  1778. X-     pmon(mtmp);
  1779. X      return(1);
  1780. X  }
  1781. X--- 348,358 ----
  1782. X          cc.x = mtmp->mx;
  1783. X          cc.y = mtmp->my;
  1784. X  dognext:
  1785. X!         remove_monster(mtmp->mx, mtmp->my);
  1786. X!         place_monster(mtmp, cc.x, cc.y);
  1787. X          pmon(mtmp);
  1788. X          set_apparxy(mtmp);
  1789. X      }
  1790. X  #endif
  1791. X      return(1);
  1792. X  }
  1793. X*** src/Old/dokick.c    Wed Sep 27 11:23:37 1989
  1794. X--- src/dokick.c    Mon Sep 25 21:29:30 1989
  1795. X***************
  1796. X*** 60,69 ****
  1797. X              mdy = mon->my + u.dy;
  1798. X              if(goodpos(mdx, mdy, mon->data)) {
  1799. X              kludge("%s reels from the blow.", Monnam(mon));
  1800. X!             levl[mon->mx][mon->my].mmask = 0;
  1801. X!             levl[mdx][mdy].mmask = 1;
  1802. X!             mon->mx = mdx;
  1803. X!             mon->my = mdy;
  1804. X              pmon(mon);
  1805. X              set_apparxy(mon);
  1806. X              }
  1807. X--- 60,67 ----
  1808. X              mdy = mon->my + u.dy;
  1809. X              if(goodpos(mdx, mdy, mon->data)) {
  1810. X              kludge("%s reels from the blow.", Monnam(mon));
  1811. X!             remove_monster(mon->mx, mon->my);
  1812. X!             place_monster(mon, mdx, mdy);
  1813. X              pmon(mon);
  1814. X              set_apparxy(mon);
  1815. X              }
  1816. X***************
  1817. X*** 214,221 ****
  1818. X              } else {
  1819. X                  if(mtmp->mpeaceful) {
  1820. X                      ESHK(mtmp)->credit += amount;
  1821. X!                     You("have %ld zorkmids in credit.",
  1822. X!                         ESHK(mtmp)->credit);
  1823. X                  } else verbalize("Thanks, scum!");
  1824. X              }
  1825. X          }
  1826. X--- 212,220 ----
  1827. X              } else {
  1828. X                  if(mtmp->mpeaceful) {
  1829. X                      ESHK(mtmp)->credit += amount;
  1830. X!                     You("have %ld zorkmid%s in credit.",
  1831. X!                     ESHK(mtmp)->credit, 
  1832. X!                     plur(ESHK(mtmp)->credit));
  1833. X                  } else verbalize("Thanks, scum!");
  1834. X              }
  1835. X          }
  1836. X***************
  1837. X*** 256,262 ****
  1838. X      while(range-- > 0) {
  1839. X          bhitpos.x += ddx;
  1840. X          bhitpos.y += ddy;
  1841. X!         if(levl[bhitpos.x][bhitpos.y].mmask) {
  1842. X              mtmp = m_at(bhitpos.x,bhitpos.y);
  1843. X              tmp_at(-1, -1); /* close call */
  1844. X              return(mtmp);
  1845. X--- 255,261 ----
  1846. X      while(range-- > 0) {
  1847. X          bhitpos.x += ddx;
  1848. X          bhitpos.y += ddy;
  1849. X!         if(MON_AT(bhitpos.x, bhitpos.y)) {
  1850. X              mtmp = m_at(bhitpos.x,bhitpos.y);
  1851. X              tmp_at(-1, -1); /* close call */
  1852. X              return(mtmp);
  1853. X***************
  1854. X*** 444,450 ****
  1855. X      /* will move, so there is no need to worry about the location,    */
  1856. X      /* which merely needs to be something other than ox, oy.    */
  1857. X      move_object(obj, u.ux, u.uy);
  1858. X!     if(cnt == 1 && !levl[x][y].mmask) newsym(x, y);
  1859. X  
  1860. X      mon = bhit(u.dx, u.dy, range, obj->olet,
  1861. X              (int (*)()) 0, (int (*)()) 0, obj);
  1862. X--- 443,450 ----
  1863. X      /* will move, so there is no need to worry about the location,    */
  1864. X      /* which merely needs to be something other than ox, oy.    */
  1865. X      move_object(obj, u.ux, u.uy);
  1866. X!     if(cnt == 1 && !MON_AT(x, y))
  1867. X!         newsym(x, y);
  1868. X  
  1869. X      mon = bhit(u.dx, u.dy, range, obj->olet,
  1870. X              (int (*)()) 0, (int (*)()) 0, obj);
  1871. X***************
  1872. X*** 460,466 ****
  1873. X      if(costly && !costly_spot(bhitpos.x,bhitpos.y)) addtobill(obj, FALSE);
  1874. X      move_object(obj, bhitpos.x, bhitpos.y);
  1875. X      stackobj(obj);
  1876. X!     if(!levl[obj->ox][obj->oy].mmask) newsym(obj->ox, obj->oy);
  1877. X      return(1);
  1878. X  }
  1879. X  #endif /* KICK */
  1880. X--- 460,467 ----
  1881. X      if(costly && !costly_spot(bhitpos.x,bhitpos.y)) addtobill(obj, FALSE);
  1882. X      move_object(obj, bhitpos.x, bhitpos.y);
  1883. X      stackobj(obj);
  1884. X!     if(!MON_AT(obj->ox, obj->oy))
  1885. X!         newsym(obj->ox, obj->oy);
  1886. X      return(1);
  1887. X  }
  1888. X  #endif /* KICK */
  1889. X***************
  1890. X*** 532,538 ****
  1891. X      /* their present order: monsters, objects, */
  1892. X      /* non-doors, doors.               */ 
  1893. X  
  1894. X!     if(maploc->mmask) {
  1895. X          kick_monster(x, y);
  1896. X          return(1);
  1897. X      }
  1898. X--- 533,539 ----
  1899. X      /* their present order: monsters, objects, */
  1900. X      /* non-doors, doors.               */ 
  1901. X  
  1902. X!     if(MON_AT(x, y)) {
  1903. X          kick_monster(x, y);
  1904. X          return(1);
  1905. X      }
  1906. X*** src/Old/dothrow.c    Wed Sep 27 11:24:13 1989
  1907. X--- src/dothrow.c    Tue Sep 26 16:08:03 1989
  1908. X***************
  1909. X*** 113,119 ****
  1910. X              return(1);
  1911. X          }
  1912. X      } else {
  1913. X!         if(obj->otyp == PICK_AXE && shkcatch(obj))
  1914. X              return(1);
  1915. X  
  1916. X          range = (int)((ACURR(A_STR) > 18 ? 20 : ACURR(A_STR))/2 - obj->owt/4);
  1917. X--- 113,119 ----
  1918. X              return(1);
  1919. X          }
  1920. X      } else {
  1921. X!         if(shkcatch(obj))
  1922. X              return(1);
  1923. X  
  1924. X          range = (int)((ACURR(A_STR) > 18 ? 20 : ACURR(A_STR))/2 - obj->owt/4);
  1925. X***************
  1926. X*** 150,156 ****
  1927. X--- 150,160 ----
  1928. X          /* the code following might become part of dropy() */
  1929. X          if (breaks(obj, TRUE)) {
  1930. X              tmp_at(-1, let);
  1931. X+ #ifdef TEXTCOLOR
  1932. X+             tmp_at(-3, (int)objects[obj->otyp].oc_color);
  1933. X+ #else
  1934. X              tmp_at(-3, (int)AT_OBJ);
  1935. X+ #endif
  1936. X              tmp_at(bhitpos.x, bhitpos.y);
  1937. X              tmp_at(-1, -1);
  1938. X              return(1);
  1939. X***************
  1940. X*** 166,172 ****
  1941. X          if(obj != uball && costly_spot(bhitpos.x, bhitpos.y) &&
  1942. X             !(mon && mon->isshk && bhitpos.x == mon->mx &&
  1943. X               bhitpos.y == mon->my && !(obj->unpaid)))
  1944. X!             subfrombill(obj);
  1945. X          stackobj(obj);
  1946. X          if(obj == uball &&
  1947. X              (bhitpos.x != u.ux || bhitpos.y != u.uy)){
  1948. X--- 170,176 ----
  1949. X          if(obj != uball && costly_spot(bhitpos.x, bhitpos.y) &&
  1950. X             !(mon && mon->isshk && bhitpos.x == mon->mx &&
  1951. X               bhitpos.y == mon->my && !(obj->unpaid)))
  1952. X!             sellobj(obj);
  1953. X          stackobj(obj);
  1954. X          if(obj == uball &&
  1955. X              (bhitpos.x != u.ux || bhitpos.y != u.uy)){
  1956. X***************
  1957. X*** 260,265 ****
  1958. X--- 264,270 ----
  1959. X              else    tmp += uwep->spe;
  1960. X          } else if(obj->otyp == BOOMERANG) tmp += 4;
  1961. X          tmp += obj->spe;
  1962. X+         tmp += hitval(obj, mon->data);
  1963. X          if(tmp >= rnd(20)) {
  1964. X              if(hmon(mon,obj,1) == TRUE){
  1965. X                /* mon still alive */
  1966. X***************
  1967. X*** 329,335 ****
  1968. X              if(mon->data == &mons[
  1969. X                  ((u.ualigntyp== U_CHAOTIC) ? PM_BLACK_UNICORN :
  1970. X                   (u.ualigntyp == U_LAWFUL) ? PM_WHITE_UNICORN
  1971. X!                           : PM_GREY_UNICORN)]) {
  1972. X                  Strcat(buf, addluck);
  1973. X                  change_luck(5);
  1974. X              } else {
  1975. X--- 334,340 ----
  1976. X              if(mon->data == &mons[
  1977. X                  ((u.ualigntyp== U_CHAOTIC) ? PM_BLACK_UNICORN :
  1978. X                   (u.ualigntyp == U_LAWFUL) ? PM_WHITE_UNICORN
  1979. X!                           : PM_GRAY_UNICORN)]) {
  1980. X                  Strcat(buf, addluck);
  1981. X                  change_luck(5);
  1982. X              } else {
  1983. X*** src/Old/eat.c    Wed Sep 27 11:24:41 1989
  1984. X--- src/eat.c    Tue Sep 26 12:59:35 1989
  1985. X***************
  1986. X*** 347,353 ****
  1987. X  #ifdef LINT    /* problem if more than 320K moves before try to eat */
  1988. X      rotted = 0;
  1989. X  #else
  1990. X!     rotted = (moves - otmp->age)/((long)(10 + rn2(20)));    /* how decomposed? */
  1991. X  #endif
  1992. X  
  1993. X      if(otmp->cursed) rotted += 2;
  1994. X--- 347,353 ----
  1995. X  #ifdef LINT    /* problem if more than 320K moves before try to eat */
  1996. X      rotted = 0;
  1997. X  #else
  1998. X!     rotted = (monstermoves - otmp->age)/((long)(10 + rn2(20)));
  1999. X  #endif
  2000. X  
  2001. X      if(otmp->cursed) rotted += 2;
  2002. X***************
  2003. X*** 505,511 ****
  2004. X          if (otmp->otyp != FORTUNE_COOKIE &&
  2005. X          otmp->otyp != DEAD_LIZARD &&
  2006. X          (otmp->cursed ||
  2007. X!          ((moves - otmp->age) > otmp->blessed ? 50 : 30)) &&
  2008. X            !rn2(7)) {
  2009. X  
  2010. X          rottenfood();
  2011. X--- 505,511 ----
  2012. X          if (otmp->otyp != FORTUNE_COOKIE &&
  2013. X          otmp->otyp != DEAD_LIZARD &&
  2014. X          (otmp->cursed ||
  2015. X!          ((monstermoves - otmp->age) > otmp->blessed ? 50 : 30)) &&
  2016. X            !rn2(7)) {
  2017. X  
  2018. X          rottenfood();
  2019. X
  2020. END_OF_FILE
  2021. if test 55684 -ne `wc -c <'patches04a'`; then
  2022.     echo shar: \"'patches04a'\" unpacked with wrong size!
  2023. fi
  2024. # end of 'patches04a'
  2025. fi
  2026. echo shar: End of archive 1 \(of 11\).
  2027. cp /dev/null ark1isdone
  2028. MISSING=""
  2029. for I in 1 2 3 4 5 6 7 8 9 10 11 ; do
  2030.     if test ! -f ark${I}isdone ; then
  2031.     MISSING="${MISSING} ${I}"
  2032.     fi
  2033. done
  2034. if test "${MISSING}" = "" ; then
  2035.     echo You have unpacked all 11 archives.
  2036.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  2037. else
  2038.     echo You still need to unpack the following archives:
  2039.     echo "        " ${MISSING}
  2040. fi
  2041. ##  End of shell archive.
  2042. exit 0
  2043.